<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------
use think\facade\Route;

// 注册路由
Route::post('Register', 'Register/index');

// 登录路由
Route::post('login', 'Login/index');

// 检查登录状态路由
Route::get('login/check', 'Login/check');

// 退出登录路由
Route::post('logout', 'Logout/index');

// 获取用户信息路由
Route::get('UserController/getUser', 'UserController/getUser');

// 更新用户信息路由
Route::post('UserController/updateUser', 'UserController/updateUser');

// 更新用户头像路由
Route::post('UserController/updateUserImage', 'UserController/updateUserImage');

// 更新用户密码路由
Route::post('UserController/updatePassword', 'UserController/updatePassword');

// 获取卡片信息
Route::get('YardInfo/getYardInfo', 'YardInfo/getYardInfo');

// 获取主页卡片列表
Route::get('YardInfo/getYardList1', 'YardInfo/getYardList1');

//获取类型卡片列表
Route::get('YardInfo/getYardList2', 'YardInfo/getYardList2');

// 搜索场地
Route::get('Search/searchYard', 'Search/searchYard');

//获取场地信息
Route::get('yard/details', 'YardController/getYardDetails');

//走马灯
Route::get('YardInfo/zmd', 'YardInfo/zmd');
//获取用户信息
Route::get('adminuser', 'adminuser/index');
// //获取场地信息
// Route::get('adminyard', 'adminyard/index');

// 显示管理员界面
// Route::get('usertype', 'usertype/index');

// 检查管理员权限
Route::get('usertype/checkAdmin', 'usertype/checkAdmin');

// 预定功能
Route::post('reserve', 'Reserve/index');

// 管理员删除用户信息路由
Route::post('UserController/deleteUser', 'UserController/deleteUser');

// 管理员删除场地信息路由
Route::post('adminyard/deleteyard', 'adminyard/deleteyard');

//获取订单信息
Route::get('YardInfo/getOrder', 'YardInfo/getOrder');

//获取所有场地列表
Route::get('YardInfo/getYardList3', 'YardInfo/getYardList3');

// 管理员删除场地信息路由
Route::post('adminyard/deleteorder', 'adminyard/deleteorder');

//获取公告
Route::get('Announcement/getLatest', 'Announcement/getLatest');
Route::post('Announcement/create', 'Announcement/create');